﻿// (c) Copyright Microsoft Corporation.   
// This source is subject to the Microsoft Public License (Ms-PL).   
// Please see http://go.microsoft.com/fwlink/?LinkID=131993 for details.   
// All other rights reserved.   

#if SILVERLIGHT
using System.Windows.Browser;
#else
using System.Web;
#endif

namespace Controls
{
    /// <summary>
    /// Utility methods.
    /// </summary>
    internal static class Extensions
    {
        /// <summary>
        /// Url encodes a string.
        /// </summary>
        /// <param name="s">The string.</param>
        /// <returns>Returns the Url-encoded string.</returns>
        public static string UrlEncode(this string s)
        {
            return HttpUtility.UrlEncode(s);
        }
    }
}